package org.jsola.hr.web;

import io.swagger.annotations.Api;
import io.swagger.annotations.ApiImplicitParam;
import io.swagger.annotations.ApiImplicitParams;
import io.swagger.annotations.ApiOperation;
import org.jsola.core.Page;
import org.jsola.core.Result;
import org.jsola.hr.dto.BookingsInfoAddDTO;
import org.jsola.hr.dto.BookingsInfoUpdateDTO;
import org.jsola.hr.query.BookingsInfoQuery;
import org.jsola.hr.vo.BookingsInfoListVO;
import org.jsola.hr.vo.BookingsInfoVO;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.core.io.Resource;
import org.springframework.http.ResponseEntity;

import java.util.List;

/**
 * 预约业务人员信息表
 *
 * @author zhr
 */
@Api(tags = "hr-预约业务人员信息表")
public interface IBookingsInfoControllerAPI {

    /**
     * 新增预约业务人员信息表
     *
     * @param bookingsInfoAddDTO 预约业务人员信息表新增实体
     * @return 预约业务人员信息表展示对象
     */
    @ApiOperation(value = "新增预约业务人员信息表")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "bookingsInfoAddDTO", dataType = "BookingsInfoAddDTO", value = "新增预约业务人员信息表", paramType = "body")
    })
    Result<BookingsInfoVO> save(BookingsInfoAddDTO bookingsInfoAddDTO);


    /**
     * 发送短信
     *
     * @param phone 电话
     * @return code
     */
    @ApiOperation(value = "发送预约验证码短信")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "phone", dataType = "String", value = "电话", paramType = "path")
    })
    Result<String> sendBookingsMessage(@PathVariable String phone);


    /**
     * 修改预约业务人员信息表
     *
     * @param bookingsInfoUpdateDTO 预约业务人员信息表
     * @return 更新数量
     */
    @ApiOperation(value = "修改预约业务人员信息表")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "bookingsInfoUpdateDTO", dataType = "BookingsInfoUpdateDTO", value = "修改预约业务人员信息表", paramType = "body")
    })
    Result<Integer> update(BookingsInfoUpdateDTO bookingsInfoUpdateDTO);




    /**
     * 删除单个预约业务人员信息表，彻底删除
     *
     * @param bookingsInfoId 预约业务人员信息表id
     * @return 删除数量
     */
    @ApiOperation(value = "删除单个预约业务人员信息表，彻底删除")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "bookingsInfoId", dataType = "Long", value = "预约业务人员信息表id", paramType = "path")
    })
    Result<Integer> delete(Long bookingsInfoId);


    /**
     * 批量删除预约业务人员信息表，彻底删除
     *
     * @param bookingsInfoIds 预约业务人员信息表id集合
     * @return 删除数量
     */
    @ApiOperation(value = "批量删除预约业务人员信息表，彻底删除")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "bookingsInfoIds", dataType = "Long[]", value = "预约业务人员信息表id数组", paramType = "body", allowMultiple = true)
    })
    Result<Integer> deleteBatch(Long[] bookingsInfoIds);


    /**
     * 根据预约业务人员信息表id查询预约业务人员信息表详情
     *
     * @param bookingsInfoId 预约业务人员信息表id
     * @return 预约业务人员信息表详情
     */
    @ApiOperation(value = "根据预约业务人员信息表id查询预约业务人员信息表详情")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "bookingsInfoId", dataType = "Long", value = "预约业务人员信息表id", paramType = "path")
    })
    Result<BookingsInfoVO> findById(Long bookingsInfoId);

    /**
     * 根据预约业务人员userId查找预约业务人员信息表详情
     *
     * @return 预约业务人员信息表详情
     */
    @ApiOperation(value = "根据userId查找预约业务人员详情信息")
    Result<BookingsInfoVO> selectByUserId();


    /**
     * 查询预约业务人员信息表
     *
     * @param bookingsInfoQuery 预约业务人员信息表查询参数
     * @return page
     */
    @ApiOperation(value = "查询预约业务人员信息表")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "bookingsInfoQuery", dataType = "BookingsInfoQuery", value = "预约业务人员信息表查询参数", paramType = "query")
    })
    Result<List<BookingsInfoListVO>> listAll(BookingsInfoQuery bookingsInfoQuery);


    /**
     * 分页查询预约业务人员信息表
     *
     * @param bookingsInfoQuery 预约业务人员信息表查询参数
     * @return page
     */
    @ApiOperation(value = "分页查询预约业务人员信息表")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "bookingsInfoQuery", dataType = "BookingsInfoQuery", value = "预约业务人员信息表查询参数", paramType = "query")
    })
    Result<Page<BookingsInfoListVO>> page(BookingsInfoQuery bookingsInfoQuery);

    /**
     * 预约业务人员信息表导出excel
     * @param bookingsInfoQuery 预约业务人员信息表查询参数
     * @return excel
     */
    @ApiOperation(value = "预约业务人员信息表导出excel")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "bookingsInfoQuery", dataType = "BookingsInfoQuery", value = "预约业务人员信息表查询参数", paramType = "query")
    })
    ResponseEntity<Resource> export(BookingsInfoQuery bookingsInfoQuery);


}

